<extend name="Common:common"/>
<block name="main">

    <div class="main-content">
        <div class="breadcrumbs" id="breadcrumbs">
            <script type="text/javascript">
                try {
                    ace.settings.check('breadcrumbs', 'fixed')
                } catch (e) {
                }
            </script>

            <ul class="breadcrumb">
                <li>
                    <i class="icon-home home-icon"></i>
                    <a href="#"> 云系统管理平台</a>
                </li>

                <li>
                    <a href="#">系统基本信息</a>
                </li>
                <li class="active">折线图</li>
            </ul>
            <!-- .breadcrumb -->
            <!-- #nav-search -->
        </div>

        <div class="page-content">
            <h1>{$title}</h1>
            <hr/>
            <div id="main" style="width: 100%;height:400px;"></div>

        </div>
       </div><!-- /.page-content -->
    </div><!-- /.main-content -->
    <script src="__PUBLIC__/Common/static/js/echarts.common.min.js"></script>
    <script type="text/javascript">
        // 基于准备好的dom，初始化echarts实例
        var myChart = echarts.init(document.getElementById('main'));
        data_time = eval('{$Time}');
        data_alias_x = eval('{$AudioFrameRate}');
        data_alias_y = eval('{$VideoFrameRate}');
        option = {
            title: {
                text: '流监控推流信息'
            },
            tooltip: {
                trigger: 'axis'
            },
            legend: {
                data:['视频帧率','音频帧率']
            },
            grid: {
                left: '1%',
                right: '1%',
                bottom: '8%',
                containLabel: true
            },
            toolbox: {
                feature: {
                    saveAsImage: {}
                }
            },
            xAxis: {
                type: 'category',
                boundaryGap: false,
                data: data_time
            },
            yAxis: {
                type: 'value'
            },
            series: [
                {
                    name:'视频帧率',
                    type:'line',
                    stack: '总量',
                    data:data_alias_x
                },
                {
                    name:'音频帧率',
                    type:'line',
                    stack: '总量',
                    data:data_alias_y
                }
            ]
        };

        // 使用刚指定的配置项和数据显示图表。
        myChart.setOption(option);
    </script>
</block>
